import request from '@/utils/request'

// 获取员工列表
export const getEmpList = (params) => request.get('/emps', { params })

// 新增员工
export const addEmp = (data) => request.post('/emps', data)

// 根据id查询员工
export const getEmpById = (id) => request.get(`/emps/${id}`)

// 更新员工
export const updateEmp = (data) => request.put('/emps', data)

// 删除员工
export const deleteEmp = (ids) => request.delete(`/emps?ids=${ids}`)

// 获取所有员工
export const getAllEmp = () => request.get('/emps/list')
